﻿<%@ Page Language="C#" AutoEventWireup="true" EnableEventValidation="false" CodeBehind="Project_Search.aspx.cs" Inherits="EcSalseManage.EcSalse.Project_Search" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>项目销售管理系统-查找项目</title>
    <link href="/css/skin.css" type="text/css" rel="stylesheet">
    <script language="javascript" type="text/javascript" src="/js/My97DatePicker/WdatePicker.js"></script>
    <script language="javascript" type="text/javascript" src="/js/net.js"></script>
    <script type="text/javascript">


        function DataCheck() {
            if (document.all("txtSignDate").value.length != 0 || document.all("txtSignDateEnd").value.length != 0
			    ) {
                if (document.all("txtSignDate").value.length != 0 && document.all("txtSignDateEnd").value.length != 0) {
                    return true;
                }
                alert("请输入起至时间条件！");
                document.all("txtSignDate").focus();
                return false;
            }
            return true;
        }

        function FillCity(oElem, oTarget) {
            var strValue = oElem.options[
                     oElem.selectedIndex].value;
            var url = '../PageCommon/ProjectCitySearch.aspx';
            var strParams = 'q=' + strValue +
          "&f=" + oTarget.form.name +
          "&e=" + oTarget.name;
            var loader1 = new 
        net.ContentLoader(url, FillDropDown, null,
                    "POST", strParams);
        }

        function FillDistrict(oElem, oTarget) {
            var strValue = oElem.options[
                     oElem.selectedIndex].value;
            var url = '../PageCommon/ProjectDistrictSearch.aspx';
            var strParams = 'q=' + strValue +
          "&f=" + oTarget.form.name +
          "&e=" + oTarget.name;
            var loader1 = new 
        net.ContentLoader(url, FillDropDown, null,
                    "POST", strParams);
        }

        function FillDropDown() {
            var xmlDoc = this.req.responseXML.documentElement;

            var xSel = xmlDoc.
           getElementsByTagName('selectElement')[0];
            var strFName = xSel.
           childNodes[0].firstChild.nodeValue;
            var strEName = xSel.
           childNodes[1].firstChild.nodeValue;

            var objDDL = document.forms[strFName].
           elements[strEName];
            objDDL.options.length = 0;

            var xRows = xmlDoc.
          getElementsByTagName('entry');
            for (i = 0; i < xRows.length; i++) {
                var theText = xRows[i].
              childNodes[0].firstChild.nodeValue;
                var theValue = xRows[i].
              childNodes[1].firstChild.nodeValue;
                var option = new Option(theText,
                            theValue);
                objDDL.options.add(option,
                          objDDL.options.length);
            }
        }

    </script>
    <style type="text/css">
        
	.mainDiv { SCROLLBAR-FACE-COLOR: #9999ff; OVERFLOW: auto; WIDTH: expression(document.body.clientWidth-20); HEIGHT: expression((document.body.clientHeight-this.offsetTop-20>this.children[0].offsetHeight)?(this.children[0].offsetHeight+20) : (document.body.clientHeight-this.offsetTop-20)) } 
    TD { FONT-SIZE: 15px }
    
    </style>
</head>
<body>
<table width="100%" border="0" cellpadding="0" cellspacing="0">
  <tr>
    <td width="17" valign="top" background="../images/mail_leftbg.gif"><img src="../images/left-top-right.gif" width="17" height="29" /></td>
    <td valign="top" background="../images/content-bg.gif">
    <table width="100%" height="31" border="0" cellpadding="0" cellspacing="0" class="left_topbg" id="table2">
      <tr>
        <td height="31"><div class="titlebt">查找项目</div></td>
      </tr>
    </table>
    </td>
    <td width="16" valign="top" background="../images/mail_rightbg.gif"><img src="../images/nav-right-bg.gif" width="16" height="29" /></td>
  </tr>
   <tr>
    <td valign="middle" background="../images/mail_leftbg.gif">&nbsp;</td>
    <td valign="top" bgcolor="#F7F8F9">
    <table width="98%" border="0" align="center" cellpadding="0" cellspacing="0">
             <tr>
                <td colspan="4" valign="top">
                <!--内容区域 -->
                        <form id="form1" runat="server">
       <center>
         <table  style="line-height:34px">
             <tr style="line-height:normal;">
                 <td align="center" colspan="4" style="border-bottom:1px solid #cccccc;"><span id="Span1" style="font-size:28px;"><br> 查找项目</span><br /><br /></td>
             </tr>
             <tr style="line-height:normal;">
                <td colspan="4">&nbsp;</td>
             </tr>
            <tr>
                <td ><span class="detailTitle">项目名称：</span></td>
                <td style="width: 350px;" align="left"><asp:TextBox ID="txtProjectName" runat="server" MaxLength="50" Style="text-align: center"
                                                                                            TabIndex="7" Width="200px"></asp:TextBox></td>
                <td><span  class="detailTitle">所属部门：</span></td>
                <td align="left"><asp:DropDownList ID="ddlDepartment" runat="server" Width="200px" TabIndex="38">
                                                                                        </asp:DropDownList></td>
            </tr>   
            <tr>
                <td><span class="detailTitle">发展商名称：</span></td>
                <td align="left"><asp:TextBox ID="txtDeveloper" runat="server" MaxLength="50" Style="text-align: center"
                                                                                            TabIndex="7" Width="200"></asp:TextBox></td>
                <td ><span class="detailTitle">项目现况：</span></td>
                <td align="left">
                    <asp:DropDownList ID="ddlProjectState" runat="server" Width="200" TabIndex="38"></asp:DropDownList>
                </td>
            </tr>
            <tr>
                <td  align="left"><span class="detailTitle">合同签署日期：</span></td>
                <td align="left" ><asp:TextBox ID="txtSignDate" runat="server" MaxLength="30" Style="text-align: center"
                                                                                            TabIndex="7" Width="100" class="Wdate" onclick="WdatePicker()"></asp:TextBox>至<asp:TextBox ID="txtSignDateEnd" runat="server" MaxLength="30" Style="text-align: center"
                                                                                            TabIndex="7" Width="100" class="Wdate" onclick="WdatePicker()"></asp:TextBox>
                                                                                            
                </td>
                <td align="left">
                    <span class="detailTitle">合同签署类型：</span>
                </td>
                <td align="left">
                    <asp:DropDownList ID="ddlSignType" runat="server" Width="200" TabIndex="38" > </asp:DropDownList>
                </td>
               
            </tr>

             <tr>
                <td><span class="detailTitle">项目地址：</span></td>
                <td align="left" colspan="3">
                <asp:DropDownList ID="ddlDeveloperProvince" runat="server" Width="73px" TabIndex="20"></asp:DropDownList>
                <asp:DropDownList ID="ddlDeveloperCity" runat="server" Width="73px" TabIndex="21"></asp:DropDownList>
                <asp:DropDownList ID="ddlDeveloperDistrict" runat="server" Width="73px" TabIndex="22"></asp:DropDownList>
                <asp:TextBox ID="txtDeveloperAddress" runat="server" Width="202px"></asp:TextBox>
                </td>
            </tr>
    <%--        <tr>
                <td><span class="detailTitle">产品类型：</span></td>
                <td align="left" colspan="3">
                    <asp:CheckBoxList ID="chklProductType" runat="server" 
                        RepeatDirection="Horizontal" class="detailTitle">
                    </asp:CheckBoxList>
                </td>
            </tr>--%>
   <%--         <tr>
                <td><span class="detailTitle">代理期：</span></td>
                <td align="left" colspan="3">
                <table><tr><td>
                   <asp:TextBox ID="txtDateStart" runat="server" MaxLength="50" Style="text-align: center" TabIndex="7" Width="100" class="Wdate" onclick="WdatePicker()"></asp:TextBox> 至
                    <asp:TextBox ID="txtDateEnd" runat="server" MaxLength="50" Style="text-align: center" TabIndex="7" Width="100" class="Wdate" onclick="WdatePicker()"></asp:TextBox>
                &nbsp;&nbsp;<span class="detailTitle">代理类型：</span> </td><td>
               <asp:CheckBoxList ID="chklAgencyType" runat="server" 
                        RepeatDirection="Horizontal" class="detailTitle" 
                        >
                    </asp:CheckBoxList>
                   </td></tr></table>
                </td>
          
            </tr>--%>
             <tr>
                <td  colspan="4">
                 <center>
                    <asp:Button ID="btnSearch" runat="server" Text=" 查 询 "  OnClientClick="" onclick="btnSearch_Click"
                          /> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<asp:Button ID="btnReset" runat="server" Text=" 重 置 " />
                  </center>
                </td>
            
            </tr>
            <tr>
                <td  colspan="4">
                        <div class="mainDiv" style=" width:800px; height:300px;">
                         <asp:GridView ID="GridView1" runat="server" Width="800px" 
                             AutoGenerateColumns="False" onrowdatabound="GridView1_RowDataBound" 
                             DataKeyNames="Project_ID" >
                             <Columns>
                             <asp:BoundField DataField="Project_NO" HeaderText="项目编号" >
                                <HeaderStyle Width="100px" />
                                <ItemStyle Width="100px" />
                            </asp:BoundField>
                            <asp:BoundField DataField="Project_Name" HeaderText="项目名称" >
                                <HeaderStyle Width="100px"  />
                                <ItemStyle Width="100px" />
                            </asp:BoundField>
                            <asp:BoundField DataField="Project_Developer" HeaderText="发展商名称" >
                                <HeaderStyle Width="100px" />
                                <ItemStyle Width="100px" />
                            </asp:BoundField>
                            <asp:BoundField DataField="Project_Detail_ProjectAddress" HeaderText="项目地址" >
                                <HeaderStyle Width="200px" />
                                <ItemStyle Width="200px" />
                            </asp:BoundField>
                            <asp:BoundField DataField="Project_PresentID" HeaderText="项目现况" >
                                <HeaderStyle Width="140px" />
                                <ItemStyle Width="140px" />
                            </asp:BoundField>
                               <asp:BoundField DataField="Project_SignDate" HeaderText="合同签署日期" DataFormatString="{0:d}" HtmlEncode="False" >
                                <HeaderStyle Width="120px" />
                                <ItemStyle Width="120px" />
                            </asp:BoundField>
                            <asp:BoundField DataField="Project_DepartmentID" HeaderText="所属部门" >
                                <HeaderStyle Width="140px" />
                                <ItemStyle Width="140px" />
                            </asp:BoundField>
                            <asp:BoundField DataField="Project_Audit" HeaderText="审核状态" >
                                <HeaderStyle Width="40px" />
                                <ItemStyle Width="40px" />
                            </asp:BoundField>
                            
                            <asp:TemplateField HeaderText="编辑项目" >
                                        <ItemTemplate>
                                            <a><img alt="编辑" src="../images/edit.gif" /></a>
                                        </ItemTemplate>
                                        <ItemStyle Width="50px" />
                            </asp:TemplateField>
                            
                            <asp:TemplateField HeaderText="新增成交" >
                                        <ItemTemplate>
                                            <a><img alt="编辑" src="../images/edit.gif" /></a>
                                        </ItemTemplate>
                                        <ItemStyle Width="50px" />
                            </asp:TemplateField>

                     
                          </Columns>
                           <RowStyle HorizontalAlign="Center" />
                           <PagerStyle HorizontalAlign="Center" />
                          <HeaderStyle Font-Bold="True" ForeColor="#FFFFCC" BackColor="#990000"></HeaderStyle>
                       </asp:GridView>
                    </div>
                </td>
            </tr>
          </table>
       </center>
    </form>
                
                </td>
        </tr>
        </tr>
       <tr>
        <td height="40" colspan="4"><table width="100%" height="1" border="0" cellpadding="0" cellspacing="0" bgcolor="#CCCCCC">
       <tr>
          <td></td>
       </tr>
        </table></td>
      </tr>
      <tr>
        <td width="2%">&nbsp;</td>
        <td width="51%" class="left_txt"><img src="../images/icon-mail2.gif" width="16" height="11"> 客户服务邮箱：servers@centaline.com<br>
              <img src="../images/icon-phone.gif" width="17" height="14"> 官方网站：http://www.centaline.com.cn/</td>
        <td>&nbsp;</td>
        <td>&nbsp;</td>
      </tr>
    </table>
    </td>
    <td background="../images/mail_rightbg.gif">&nbsp;</td>
  </tr>
    
    
   <tr>
    <td valign="bottom" background="../images/mail_leftbg.gif"><img src="../images/buttom_left2.gif" width="17" height="17" /></td>
    <td background="../images/buttom_bgs.gif"><img src="../images/buttom_bgs.gif" width="17" height="17"></td>
    <td valign="bottom" background="../images/mail_rightbg.gif"><img src="../images/buttom_right2.gif" width="16" height="17" /></td>
  </tr>
</table>
</body>
</html>
